import {gql} from "@apollo/client";

export const PRODUCT_AD_LIST = gql`
query MyQuery {
  productAd {
    advertisingList {
      coverAddr
      createTime
      id
      productId
      updateTime
    }
  }
}
`;

export const PRODUCT_AD_CREATE = gql`
mutation MyMutation($coverAddr: String, $productId: String) {
  productAd {
    createAdvertising(input: {productId: $productId, coverAddr: $coverAddr}) {
      coverAddr
      createTime
      id
      productId
      updateTime
    }
  }
}
`;


export const PRODUCT_AD_DELETE = gql`
mutation MyMutation(
  $id: String
) {
  productAd {
    deleteAdvertising(id: $id)
  }
}
`;
